/**
 * 
 */
package ru.olympus.antonyhands.ao.client.widgets;

import ru.olympus.antonyhands.ao.client.AOHelperServiceAsync;
import ru.olympus.antonyhands.ao.shared.item.EItemParentType;
import ru.olympus.antonyhands.ao.shared.item.EItemsViewType;

import com.google.gwt.user.client.ui.Grid;
import com.google.gwt.user.client.ui.VerticalPanel;

/**
 * @author AntonyHands
 * @since 08.03.2012
 */
public class ItemByCraftSkillInfoPanel extends VerticalPanel {

	public ItemByCraftSkillInfoPanel(AOHelperServiceAsync service) {
		Grid table = new Grid(2, 2);
		add(table);

		table.setHTML(0, 0, "Навык производства");
		table.setHTML(1, 0, "Предмет");

		CraftSkillListBox _itemCraftSkill = new CraftSkillListBox(service, false);
		table.setWidget(0, 1, _itemCraftSkill);

		ItemsListBox _items = new ItemsListBox(service, _itemCraftSkill,
				EItemParentType.CRAFT_SKILL, EItemsViewType.CRAFTABLE_WITH_CRAFT_LEVEL);
		table.setWidget(1, 1, _items);

		add(new ItemInfoGrid(service, _items));
	}
}
